<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core">

    <ui:composition template="/template.xhtml">
        <ui:define name="title">
            <h:outputText value="#{bundle.EditCursoTitle}"></h:outputText>
        </ui:define>
        <ui:define name="body">
            <h:panelGroup id="messagePanel" layout="block">
                <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
            </h:panelGroup>
            <h:form>
                <h:panelGrid columns="2">
                    <h:outputLabel value="#{bundle.EditCursoLabel_idCurso}" for="idCurso" />
                    <h:inputText id="idCurso" value="#{cursoController.selected.idCurso}" title="#{bundle.EditCursoTitle_idCurso}" required="true" requiredMessage="#{bundle.EditCursoRequiredMessage_idCurso}"/>
                    <h:outputLabel value="#{bundle.EditCursoLabel_curso}" for="curso" />
                    <h:inputText id="curso" value="#{cursoController.selected.curso}" title="#{bundle.EditCursoTitle_curso}" />
                    <h:outputLabel value="#{bundle.EditCursoLabel_asignatura}" for="asignatura" />
                    <h:inputText id="asignatura" value="#{cursoController.selected.asignatura}" title="#{bundle.EditCursoTitle_asignatura}" />
                </h:panelGrid>
                <h:commandLink action="#{cursoController.update}" value="#{bundle.EditCursoSaveLink}"/>
                <br />
                <br />
                <h:link outcome="View" value="#{bundle.EditCursoViewLink}"/>
                <br />
                <h:commandLink action="#{cursoController.prepareList}" value="#{bundle.EditCursoShowAllLink}" immediate="true"/>
                <br />
                <br />
                <h:link outcome="/index" value="#{bundle.EditCursoIndexLink}" />
            </h:form>
        </ui:define>
    </ui:composition>

</html>
